<template>
  <div>
      <el-row :gutter="10">
        <el-col :span="6"><h4>借款信息</h4></el-col>
      </el-row>
      <el-row :gutter="10">
        <el-col :span="6" :offset="1">借款金额:{{borrowInfo.borrowInfo.amount}}</el-col>
        <el-col :span="6" :offset="1">借款期限:{{borrowInfo.borrowInfo.period+'个月'}}</el-col>
      </el-row>
      <el-row :gutter="10">
        <el-col :span="6" :offset="1">年化率:{{borrowInfo.borrowInfo.borrowYearRate*12+'%'}}</el-col>
        <el-col :span="6" :offset="1">还款方式:{{borrowInfo.borrowInfo.param.returnMethod}}</el-col>
      </el-row>
      <el-row :gutter="10">
        <el-col :span="6" :offset="1">资金用途:{{borrowInfo.borrowInfo.param.moneyUse}}</el-col>
        <el-col :span="6" :offset="1">状态:{{borrowInfo.borrowInfo.param.status}}</el-col>
      </el-row>
      <el-row :gutter="10">
        <el-col :span="6" :offset="1">创建时间:{{borrowInfo.borrowInfo.createTime}}</el-col>
      </el-row>
      <el-row :gutter="10">
        <el-col :span="6"><h4>收款人信息</h4></el-col>
      </el-row>
      <el-row :gutter="10">
        <el-col :span="6" :offset="1">借款人{{borrowInfo.borrower.name}}</el-col>
        <el-col :span="6" :offset="1">手机:{{borrowInfo.borrower.mobile}}</el-col>
      </el-row>
      <el-row :gutter="10">
        <el-col :span="6" :offset="1">身份证  :{{borrowInfo.borrower.idCard}}</el-col>
        <el-col :span="6" :offset="1">性别:{{borrowInfo.borrower.sex}}</el-col>
      </el-row>
      <el-row :gutter="10">
        <el-col :span="6" :offset="1">年龄:{{borrowInfo.borrower.age}}</el-col>
        <el-col :span="6" :offset="1">婚否:{{borrowInfo.borrower.marry}}</el-col>
      </el-row>
      <el-row :gutter="10">
        <el-col :span="6" :offset="1">学历:{{borrowInfo.borrower.education}}</el-col>
        <el-col :span="6" :offset="1">行业:{{borrowInfo.borrower.industry}}</el-col>
      </el-row>
      <el-row :gutter="10">
        <el-col :span="6" :offset="1">月收入:{{borrowInfo.borrower.income}}</el-col>
        <el-col :span="6" :offset="1">还款来源:{{borrowInfo.borrower.returnSource}}</el-col>
      </el-row>
      <el-row :gutter="10">
        <el-col :span="6" :offset="1">创建时间:{{borrowInfo.borrower.createTime}}</el-col>
      </el-row>
       <el-row :gutter="10">
        <el-col :span="6" :offset="8" > <el-button @click="$router.push('/core/borrowInfo')" type="info" plain>返回</el-button></el-col>
         
      </el-row>
      
      
  </div>
</template>

<script>
export default {
  data() {
    return {
      borrowInfo:{
        borrower:{
          borrowerAttachVOList:[]
        },
        borrowInfo:{
          param:{}
        }

      }
    }
  },
  methods: {
    async fetchDta(id){
      const result  = await this.$API.borrowInfo.getBorrweInfo(id);
      if(result.code==200){
        this.borrowInfo =result.data.borrowerInfoDetail
    }
    },
  
  },
  mounted() {
    if(this.$route.params.id){
      this.fetchDta(this.$route.params.id)
    }
  }
}
</script>

<style lang="css" >
  .el-col{
    margin-bottom: 10px;
  }
</style>>

</style>